import request from '@/utils/request'

// 查询诚意金管理列表
export function listFinance(buyid) {
  return request({
    url: '/house_sale/finance/list1/'+buyid,
    method: 'get',
  })
}
//获取付款方式
export function getPaidType(){
  return request({
    url: '/house_sale/finance/paidtypeList',
    method: 'get',
  })
}
//作废
export function beInvalid(form2){
  return request({
    url: '/house_sale/finance/invalid',
    method: 'put',
    data: form2
  })
}
// 查询收款管理列表
export function listFinance1(query) {
  return request({
    url: '/house_sale/finance/list',
    method: 'get',
    params: query
  })
}

// 查询收款管理详细
export function getFinance(financeid) {
  return request({
    url: '/house_sale/finance/' + financeid,
    method: 'get'
  })
}

// 新增收款管理
export function addFinance(data) {
  return request({
    url: '/house_sale/finance',
    method: 'post',
    data: data
  })
}

// 修改收款管理
export function updateFinance(data) {
  return request({
    url: '/house_sale/finance',
    method: 'put',
    data: data
  })
}

// 删除收款管理
export function delFinance(financeid) {
  return request({
    url: '/house_sale/finance/' + financeid,
    method: 'delete'
  })
}
export function selectyfMoney(buyid) {
  return request({
    url: '/house_sale/finance/selectyfMoney/' + buyid,
    method: 'get'
  })
}
